{extend name="layout" /}
{block name="content"}
<header class="mui-bar mui-bar-nav header header-green statistics-header">
	<!-- <a class="mui-action-back mui-icon mui-icon-arrowthinleft mui-pull-left" href="javascript:" onclick="coco_close_window()"></a>
	<a href="{:url('share_record', ['noheader'=>1])}" class="mui-pull-right sharing" id="open-operation">
		<div class="tm-icon">
			<img src="{$images_path}statistics.png" alt="" width="16" height="16" />
		</div>
	</a> -->
	<div class="statistics-card">
		<div class="statistics-card-item">
			<div class="tm-label-no">
				<div class="uk-text-center">
					<span class="integral-number">{$uinfo.jifen}<em class="tm-df-size tm-font-bold">积分</em></span>
				</div>
				<div class="uk-margin-xsmallx-top">
					<div class="uk-text-right">
						<div class="main-content">
							<button type="button" class="mui-btn mui-btn-green" onclick="goto_exchange()">兑换</button>
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>
	<div class="main-tab">
		<div class="tm-label-small tm-bg-white border-bottom tm-label-md uk-text-center tm-df-size">
			<div class="main-content">
			<div class="tm-flex">
				<div class="tm-flex-1">
					积分操作
				</div>
				<div class="tm-flex-1">
					积分
				</div>
				<div class="tm-flex-1">
					时间
				</div>
			</div>
		</div>
		</div>
	</div>
</header>
<div class="mui-content">
	<div class="integral-table-group tm-bg-white">
		<div calss="integral-table-body">
			<ul class="mui-table-view max">
				{volist name=":get_model_func('Jifen', 'list_data', ['userid'=>$_userid])" id="v"}
				<li class="mui-table-view-cell">
					<div class="tm-df-size">
						<div class="tm-flex">
							<div class="tm-flex-1">
								{:config('JIFEN_TYPE.'.$v.typeid)}
							</div>
							<div class="tm-flex-1 uk-text-center">
								{$v.nums>=0?'+'.$v.nums:$v.nums}
							</div>
							<div class="tm-flex-1 tm-font-gray">
								{$v.addtime}
							</div>
						</div>
					</div>
				</li>
				{/volist}
			</ul>
		</div>
	</div>
	<div class="uk-text-center">
		<div class="tm-label">
			<div class="main-content">
				<span class="tm-df-size tm-font-gray">没有更多数据</span>
			</div>
		</div>
	</div>
</div>
{/block}
{block name="script"}
<script type="text/javascript">
	$(function(){
		c3_navtive_user.right_button_item1 = {
            title:"{$images_path}statistics-black.png",
            callback:function(){
                var content = new Array();
                content['title'] = "分享统计";
                content['url'] = "{$app_url}/index/member/share_record/noheader/1";
				content['target'] = "blank";
                c3_navtive_user.doActionAnsy('gotopage',content,function(){});
            }
        };
        var button_item = [
            {
                title: "{$images_path}statistics.png",
                returnTag:'1'
            }
        ];
        if("undefined" != typeof CocoObj){
            c3_navtive_user.doActionFunc("configMenu",button_item,function(datas){
                returntag = eval('(' + datas + ')');
                if(returntag.returnTag == 1){
                    var content = new Array();
                    content['title'] = "分享统计";
                    content['url'] = "{$app_url}/index/member/share_record/noheader/1";
					content['target'] = "blank";
                    c3_navtive_user.doActionAnsy('gotopage',content,function(){});
                }
                else if(returntag.returnTag == 2){
                    c3_navtive_user.doActionAnsy('openSearch',null,function(){});
                }
            });
        }
	})
</script>
<script type="text/javascript">
	function goto_exchange() {
		location.href = "{:url('exchange?token=' . $token . '&timestamp=' . time())}";
	}
</script>
{/block}